using System;
using System.ComponentModel;
using System.Runtime.Serialization;

namespace WcfService1.DTO
{
    [DataContract]
    public class DeliveryOrderElseDetailDTO : INotifyPropertyChanged
    {
        private long _DeliveryOrderDetailId;
        private InventoryDTO _Inventory;
        private decimal _Lebar;
        private int _No;
        private decimal _Panjang;
        private decimal _QtyPack;
        private decimal _QtyUnit;
        private decimal _Tinggi;
        private WarehouseDTO _Warehouse;


        [DataMember]
        public Int64 DeliveryOrderDetailId
        {
            get { return _DeliveryOrderDetailId; }
            set
            {
                _DeliveryOrderDetailId = value;
                RaisePropertyChanged("DeliveryOrderDetailId");
            }
        }

        [DataMember]
        public InventoryDTO Inventory
        {
            get { return _Inventory; }
            set
            {
                _Inventory = value;
                RaisePropertyChanged("Inventory");
            }
        }

        [DataMember]
        public Decimal QtyPack
        {
            get { return _QtyPack; }
            set
            {
                _QtyPack = value;
                RaisePropertyChanged("QtyPack");
            }
        }


        [DataMember]
        public Decimal QtyUnit
        {
            get { return _QtyUnit; }
            set
            {
                _QtyUnit = value;
                RaisePropertyChanged("QtyUnit");
            }
        }


        [DataMember]
        public Decimal Panjang
        {
            get { return _Panjang; }
            set
            {
                _Panjang = value;
                RaisePropertyChanged("Panjang");
            }
        }


        [DataMember]
        public Decimal Lebar
        {
            get { return _Lebar; }
            set
            {
                _Lebar = value;
                RaisePropertyChanged("Lebar");
            }
        }


        [DataMember]
        public Decimal Tinggi
        {
            get { return _Tinggi; }
            set
            {
                _Tinggi = value;
                RaisePropertyChanged("Tinggi");
            }
        }

        [DataMember]
        public WarehouseDTO Warehouse
        {
            get { return _Warehouse; }
            set
            {
                _Warehouse = value;
                RaisePropertyChanged("Warehouse");
            }
        }

        public int No
        {
            get { return _No; }
            set
            {
                _No = value;
                RaisePropertyChanged("No");
            }
        }

        public String DoNo { get; set; }

        #region INotifyPropertyChanged Members

        public event PropertyChangedEventHandler PropertyChanged;

        #endregion

        protected void RaisePropertyChanged(string propertyname)
        {
            PropertyChangedEventHandler handler = PropertyChanged;
            if (handler != null)
                handler(this, new PropertyChangedEventArgs(propertyname));
        }
    }
}